package org.rasterfun.language2.num

import org.rasterfun.language2.Context

/**
 *
 * @author Hans Haggstrom
 */
case class NumFunction(functionName: String, parameters: Num * ) extends Num {
  def generateCode(context: Context, s: StringBuilder) {
    s.append(" ( (float) ")
    s.append(functionName)
    s.append(" ( ")
    s.append( (parameters map { _.generateCode(context) }).mkString(", ") )
    s.append(" ) ) ")
  }
}

